package com.blog.bean.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * @author 任浩
 * @version 1.0
 */

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("course_class")
public class CourseClass {

    @TableId(type = com.baomidou.mybatisplus.annotation.IdType.AUTO)
    @TableField("id")
    private Integer id;

    @TableField("name")
    private String name;

    @TableField("create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime create_time;

    @TableField("del")
    private Integer del;

    /**
     * 此字段表明该标签是否是父标签， 父标签默认值为0，子标签默认值为父标签的id值。
     */
    @TableField("parent")
    private Integer parent;
}
